prefix=/usr
USRBINDIR=$(DESTDIR)$(prefix)/bin
ETCDIR=$(DESTDIR)/etc/dbus-1/system.d
INSTALL = install

CPP = gcc
CFLAGS =	\
		-g -Wall -Werror -Wno-unused \
		-pthread -fpic \
		`pkg-config --cflags dbus-1` \
		`pkg-config --cflags dbus-glib-1` \

LIBS=		`pkg-config --libs dbus-1` \
		`pkg-config --libs dbus-glib-1` \
#		-lxml2wbxml -lexpat

BINFILES=	\
		wappush_test_client \
		deregister.sh \
		fakesms.sh \
		register.sh \

CONFFILE = wappush_test_client_policy.conf


all:	wappush_test_client

wappush_test_client:	wappush_test_client.c
	$(CPP) $(CFLAGS) -o wappush_test_client.o -c wappush_test_client.c
	$(CPP) $(LDFLAGS) -o wappush_test_client wappush_test_client.o $(LIBS)

clean:
	$(RM) wappush_test_client *.o *~ core *.core

install :
	$(INSTALL) -m 755 $(BINFILES) $(USRBINDIR)/
	$(INSTALL) -m 755 $(CONFFILE) $(ETCDIR)/
